﻿@using rentit03_client.Models
@model dynamic
@{
    string active = "active";
}
<div id="carousel" class="carousel slide">
    <!-- Carousel items -->
    <div class="carousel-inner">
        @foreach (MovieObj movie in ViewBag.Media)
        {

            <div class="@active item" style="height:350px">
                <img src="@movie.CoverUrl" alt="" width="700px" style="position: absolute; top: -150%"/>
                <a href="@Url.Action("Index", "Movie", new { @id = movie.Id })">
                    <div class="carousel-caption">
                        <h4>@movie.Title (@movie.Year)</h4>
                        <p>@movie.Description</p>
                    </div>
                </a>
            </div>

                      active = String.Empty;
        }
    </div>
    <!-- Carousel nav -->
    <a class="carousel-control left" href="#carousel" data-slide="prev">&lsaquo;</a>
    <a class="carousel-control right" href="#carousel" data-slide="next">&rsaquo;</a>
</div>